#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QtGui/QMainWindow>
#include "dialogbuilding.h"
#include <QInputDialog>
#include <QLineEdit>
#include <QMessageBox>

namespace Ui {
    class MainWindow;
}

class MainWindow : public QMainWindow {
    Q_OBJECT
public:
    MainWindow(QWidget *parent = 0);
    ~MainWindow();

    void goToPage (QWidget *page);

protected:
    void changeEvent(QEvent *e);

private:
    Ui::MainWindow *m_ui;
    int oldPageIndex;

    bool displayDeleteSaveConfirmation();
    bool displayEndGameConfirmation();


private slots:
    void on_pushButtonDeleteLoad_clicked();
    void on_pushButtondeleteSave_clicked();
    void on_pushButtonSaveGame_clicked();
    void on_pushButtonChooseGame_clicked();
    void on_pushButtonChooseLevel_clicked();
    void on_actionNouveauPartie_triggered();
    void on_pushButtonLoadGame_clicked();
    void on_actionChargerPartie_triggered();
    void on_actionSauvegarderPartie_triggered();
    void on_actionRetourAuMenu_triggered();
    void on_buttonMenuNewGame_clicked();
    void goToOldPage();
    void goToPageMainWindow();
    void goToPageMenu();
    void goToPageChooseLevel();
    void goToPageLoad();
    void goToPageSave();
    void printDialogBuilding();
    void printDialogOptions();
    void setOptionPleinEcran(bool active);
};

#endif // MAINWINDOW_H
